Fix a crash with scaled cursors on Wayland
authorMatthias Clasen <mclasen@redhat.com>
Sun, 11 Aug 2013 18:53:14 +0000 (14:53 -0400)
committerMatthias Clasen <mclasen@redhat.com>
Sun, 11 Aug 2013 19:38:25 +0000 (15:38 -0400)
We need to initialize cursor->surface.scale to 1, since we
are dividing by it in _gdk_wayland_cursor_get_buffer.

gdk/wayland/gdkcursor-wayland.c

index 76d0fbdf12ef6287fb9d267b787c122893a8538c..e88fff5f89aaf801b343c99366513ec1b3d12ce3 100644 (file)
@@ -317,6 +317,7 @@ _gdk_wayland_display_get_cursor_for_name (GdkDisplay  *display,
                           NULL);
   private->name = g_strdup (name);
   private->serial = theme_serial;
+  private->surface.scale = 1;
 
   /* Blank cursor case */
   if (!name || g_str_equal (name, "blank_cursor"))